package servlet;

import bean.Request;
import bean.Response;
import errors.HTTPMethodNotSupportException;
import utils.Logger;

import java.io.PrintWriter;

public class NotFoundServlet extends Servlet{

    @Override
    public void doError(Request request, Response response,Exception e)  {
        PrintWriter printWriter  = new PrintWriter(response.getOutputStream());
        printWriter.println("<h1>404 错误信息如下:</h1></h1>"+ Logger.getStackTrace(e) +"</h1>");
        printWriter.flush();
    }
}
